package demo1;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: ASUS
 * Date: 2023-10-23
 * Time: 17:34
 */

class  Dog {
    public String name;
    public int age;
    public String color;

    public void eat() {
        System.out.println("吃饭！");
    }
}

class WashMachine {
    public String brand;
    public String type;
    public double weight;
    public double length;
    public double width;
    public double height;
    public String color;

    public void washClothes() {
        System.out.println("洗衣功能");
    }
    public void dryClothes(){
        System.out.println("脱水功能");
    }
    public void setTime(){
        System.out.println("定时功能");
    }

}

class Person{
    public String name;
    public int age;

    public void eat(){
        System.out.println(name+"在吃饭！");
    }
}
public class Test3 {
    public static void main(String[] args) {
        WashMachine washMachine1 = new WashMachine();
        washMachine1.brand = "小企鹅";
        System.out.println(washMachine1.brand);

        WashMachine washMachine2 = new WashMachine();
        washMachine2.brand = "海尔";
        System.out.println(washMachine2.brand);
    }
    public static void main1(String[] args) {
        Person person1 = new Person();
        person1.name = "zhangsan";
        person1.eat();
        System.out.println(person1.name);

        Person person2 = new Person();
        person2.name = "laji";
        person2.eat();
        System.out.println(person2.name);
    }
}
